<%@ taglib prefix="s" uri="/struts-tags" %>
<%--
  Created by IntelliJ IDEA.
  User: 高金磊
  Date: 2021/5/11
  Time: 17:21
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
    <link rel="icon" href="<%=basePath%>favicon.ico" type="image/ico">
    <link href="<%=basePath%>css/bootstrap.min.css" rel="stylesheet">
    <link href="<%=basePath%>css/fonts.css" rel="stylesheet">
    <link href="<%=basePath%>css/style.css" rel="stylesheet">
</head>
<body>
<s:action name="find_order_record">

    <div class="row">

        <div class="col-lg-12">
            <div class="card-toolbar clearfix">

                <form class="pull-left search-bar" method="get" action="<%=basePath%>find_order_record.action" role="form">

                    <div style="width: 500px" class="input-group">


                        <input name="key" type="text" class="form-control" value="<%=request.getParameter("key")==null?"":request.getParameter("key")%>"  placeholder="输入图书编号/订单号/书名,支持模糊搜索">
                        <span style="color:red"><s:actionerror/></span>
                        <span style="color:#24bb10"><s:actionmessage/></span>
                    </div>
                </form>
            </div>
            <div class="card">
                <div class="card-body">
                    <div class="table-responsive">
                        <h4>订单动态
                            <a href=""><span class="badge"><s:property value="#request.data.size()"/> </span></a></h4>

                        <table class="table table-hover">
                            <thead>
                            <tr>
                                <th>订单号</th>
                                <th>时间</th>
                                <th>图书名称</th>
                                <th>新状态</th>
                                <th>操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            <%--//日志id--订单号--时间--图书名字--日志内容--图书id--%>
                            <s:iterator value="#request.data" var="data">
                                <tr>
                                    <td><a class="ftsucai-ui-07" title="点击查看订单完整信息" href="UserOrderDetail.action?modify_key=<s:property value="#data[1]"/>"></a><s:property value="#data[1]"/> </td>
                                    <td><s:property value="#data[2]"/> </td>
                                    <td><a class="ftsucai-ui-07" title="点击查看本书的详细信息" href="ShowBookDetailInfo.action?modify_id=<s:property value="#data[5]"/>"></a><s:property value="#data[3]"/> </td>
                                    <td><s:property value="#data[4]"/> </td>
                                    <%--<td>--%>
                                        <%--<div class="progress progress-striped progress-sm">--%>
                                            <%--<div class="progress-bar progress-bar-success" style="width: <s:property value="#data[7]"/>%;"></div>--%>
                                        <%--</div>--%>
                                    <%--</td>--%>
                                    <td>
                                        <a style="font-size: 13px" class="ftsucai-ui-07" href="<%=basePath%>ShowBookDetailInfo.action?modify_id=<s:property value="#data[5]"/>">图书详情</a>
                                        <a style="font-size: 13px" class="ftsucai-ui-07" href="<%=basePath%>UserOrderDetail.action?modify_key=<s:property value="#data[1]"/>">订单详情</a>
                                    </td>
                                </tr>
                            </s:iterator>
                            </tbody>
                            <tfoot>

                            </tfoot>
                        </table>

                    </div>
                    <div align="center">
                        <h6>系统只保留30内的订单记录</h6>
                    </div>

                </div>
            </div>
        </div>

    </div>

</s:action>
<br>
<br>
<br>
<br>
<br>

<script type="text/javascript" src="<%=basePath%>js/jquery.min.js"></script>
<script type="text/javascript" src="<%=basePath%>js/bootstrap.js"></script>
<script type="text/javascript" src="<%=basePath%>js/perfect-scrollbar.min.js"></script>
<script type="text/javascript" src="<%=basePath%>js/main.min.js"></script>
<script type="text/javascript">
    $(function(){
        $('.search-bar .dropdown-menu a').click(function() {
            var field = $(this).data('field') || '';
            $('#search-field').val(field);
            $('#search-btn').html($(this).text() + ' <span class="caret"></span>');
        });
    });
</script>
</body>
</html>
